SCRIPT=$(basename $0)
function usage(){
    echo -e "\nUSAGE: $SCRIPT <consumer-group> \n"
    exit 1
}

if [ $# -lt 1 ] ; then
   usage
fi

export JAVA_HOME=/opt/jdk1.8.0_101

NAMESRV_ADDR=192.168.88.135:9876

MQ_HOME=/home/csdn/alibaba-rocketmq

cd $MQ_HOME/bin

#bash mqadmin consumerProgress -n $NAMESRV_ADDR | grep $1 | awk '{print $7}'

bash mqadmin consumerProgress -n $NAMESRV_ADDR > /tmp/test-queu-len.txt

cat /tmp/test-queu-len.txt | grep $1 | awk '{print $7}'

#sleep 5

#echo 44
